package cn.fengwoo.springBoot.repository;


import cn.fengwoo.springBoot.entity.Token;
import org.springframework.data.jpa.repository.JpaRepository;

import java.util.List;

/**
 * Token dao
 * DAO 集成 JpaRepository<PO,主键类型>
 * Created by fangdaji on 2018/1/10.
 */
public interface TokenRepository extends JpaRepository<Token,Integer> {

    List<Token> findByUserId(Integer userId);

    Token findByAccessToken(String accessToken);

}
